import request from '@/utils/request'

/**
 * 产线管理分页查询
 * @param {查询条件} data
 */
export function pageFacLine(query) {
	return request({
		url: 'FacManage/FacLine/pageList',
		method: 'get',
		params: query,
	})
}

/**
 * 产线管理树查询
 */
export function treeFacLine(query) {
	return request({
		url: 'FacManage/FacLine/treeList',
		method: 'get',
		params: query,
	})
}

/**
 * 新增产线管理
 * @param data
 */
export function addFacLine(data) {
	return request({
		url: 'FacManage/FacLine',
		method: 'post',
		data: data,
	})
}
/**
 * 修改产线管理
 * @param data
 */
export function updateFacLine(data) {
	return request({
		url: 'FacManage/FacLine',
		method: 'PUT',
		data: data,
	})
}
/**
 * 获取产线管理详情
 * @param {Id}
 */
export function getFacLine(id) {
	return request({
		url: 'FacManage/FacLine/' + id,
		method: 'get'
	})
}

/**
 * 删除产线管理
 * @param {主键} pid
 */
export function delFacLine(pid) {
	return request({
		url: 'FacManage/FacLine/delete',
		method: 'POST',
		data: pid
	})
}
